import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/api/articles")
public class ArticleController {

    // 其他方法...

    @DeleteMapping("/{id}")
    public ResponseEntity<?> deleteArticle(@PathVariable Long id) {
        // 调用服务层删除文章
        articleService.deleteArticle(id);
        return ResponseEntity.ok().body("文章删除成功");
    }
} 